package mest.service.cxj.impl;

import mest.VO.cxj.PlanCostorderVO;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
import mest.dao.cxj.PlanCostOrderDao;
import mest.entity.PlanCostOrder;
import mest.service.cxj.PlanCostOrderService;

import java.math.BigDecimal;
import java.util.List;

@Service
public class PlanCostOrderServiceImpl implements PlanCostOrderService {

    @Resource
    private PlanCostOrderDao planCostorderDao;


    @Override
    public Integer insertPlanCostOrder(PlanCostOrder pco, String theirDb) {
        return planCostorderDao.insertPlanCostOrder(pco,theirDb);
    }

    @Override
    public List<PlanCostorderVO> selectAllPlanCostOrder(Integer page, Integer limit,Integer status,String content, String theirDb) {
        return planCostorderDao.selectAllPlanCostOrder((page-1)*limit,limit,status,content,theirDb);
    }

    @Override
    public Integer selectCountPlanCostOrder(Integer status,String content,String theirDb) {
        return planCostorderDao.selectCountPlanCostOrder(status,content,theirDb);
    }

    @Override
    public Integer changeStatus(Integer id,String theirDb) {
        return planCostorderDao.changeStatus(id,theirDb);
    }

    @Override
    public Integer modifyPlanCostOrder(PlanCostOrder pco, String theirDb) {
        return planCostorderDao.modifyPlanCostOrder(pco,theirDb);
    }

    @Override
    public PlanCostOrder selectPlanCostOrderById(Integer id, String theirDb) {
        return planCostorderDao.selectPlanCostOrderById(id, theirDb);
    }

    @Override
    public Integer updatePlanCostOrderByMoney(Integer id, BigDecimal hasBennMoney, String theirDb) {
        return planCostorderDao.updatePlanCostOrderByMoney(id, hasBennMoney, theirDb);
    }

}
